<template>
  <div  class="box">
        组件2 {{count}}
  </div>
</template>

<script>
import { mapState} from 'vuex'
export default {
 computed: {
    ...mapState([ 
      'count',
      'msg'
    ])
  } ,
}
</script>

<style lang="css" scoped>
.box{
  border: 3px solid #ccc;
  width: 400px;
  padding: 10px;
  margin: 20px;
}
</style>